{{ header }}

<div id="account-order" class="container">

    <div class="row">{{ column_left }}
        {% if column_left and column_right %}
            {% set class = 'col-sm-6' %}
        {% elseif column_left or column_right %}
            {% set class = 'col-sm-9' %}
        {% else %}
            {% set class = 'col-sm-12' %}
        {% endif %}
        <div id="content" class="col-sm-12">
            {#{{ content_top }}#}
            <h1>{{ "訂單" }}</h1>
            {% if orders %}
                <div class="table-responsive">
                    <table class="table table-bordered table-hover">
                        <thead>
                        <tr>
                            <td class="text-right">{{ column_order_id }}</td>
                            {#<td class="text-left">{{ column_customer }}</td>#}
                            <td class="text-right">{{ '数量' }}</td>
                            <td class="text-left">{{ column_status }}</td>
                            <td class="text-right">{{ column_total }}</td>
                            <td class="text-left">{{ column_date_added }}</td>
                            <td></td>
                        </tr>
                        </thead>
                        <tbody>
                        {% for order in orders %}
                            <tr>
                                <td class="text-right">#{{ order.order_id }}</td>
                                {#<td class="text-left">{{ order.name }}</td>#}
                                <td class="text-right">{{ order.products }}</td>
                                <td class="text-left">{{ order.status }}</td>
                                <td class="text-right">{{ order.total }}</td>
                                <td class="text-left">{{ order.date_added }}</td>
                                <td class="text-right"><a href="{{ order.view }}" data-toggle="tooltip"
                                                          title="{{ button_view }}" class="btn btn-info"><i
                                                class="fa fa-eye"></i></a></td>
                            </tr>
                        {% endfor %}
                        </tbody>
                    </table>
                </div>
                <div class="row">
                    <div class="col-sm-6 text-left">{{ pagination }}</div>
                    <div class="col-sm-6 text-right">{{ results }}</div>
                </div>order-empty
            {% else %}
                  {#<p>{{ text_empty }}</p>#}
                <div class="order-empty">
                    <div class="empty-img">
                        <i class="fa fa-shopping-bag"></i>
                    </div>
                    未找到對應訂單
                </div>

            {% endif %}

            {{ content_bottom }}</div>
    </div>
</div>

</body></html>
